<%--
  Created by IntelliJ IDEA.
  User: 王宝田
  Date: 2022/8/31
  Time: 8:29
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>注册</title>
    <link rel="stylesheet" href="../css/login.css"/>
    <link rel="stylesheet" href="https://cdn.staticfile.org/font-awesome/4.7.0/css/font-awesome.css">

</head>


<style>
    body{
        background: url(../images/ww.jpg) no-repeat;
        background-size:100% auto;
    }
</style>
<body >
<div align="center">
    <h1>注册</h1>
    <form  name="form" method="post" action="zhuce" onsubmit="return userCheck()">
        <input type="text" name="uname" placeholder="用户名"><br/>
        <input type="text"  name="upassword" placeholder="密码"><br/>
        <input type="text" name="email" placeholder="邮箱"><br/>
        <select name="role">
            <option  value="parent">家长</option>
            <option  value="teacher">老师</option>
        </select>
        <input type="submit" name="submit" value="注册"><br/>
        <a href="index">返回</a>
    </form>
</div>
<script type="text/javascript">
    function userCheck(){
        if(document.form.uname.value==""){
            window.alert("请输入用户名");
            return false;
        }
        if(document.form.upassword.value==""){
            window.alert("请输入用户密码");
            return false;
        }if(document.form.email.value==""){
            window.alert("请输入邮箱");
            return false;
        }

        return true;
    }
</script>
</body>
</html>
